package com.dgw.services.impl;

import com.dgw.dao.IUserDaoMapper;
import com.dgw.domain.User;
import com.dgw.services.IUserService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @program: SSM-Vue
 * @description:
 * @author: Mr.Dai
 * @create: 2019-12-21 11:08
 **/
@Service
public class UserServiceImpl implements IUserService {


    private IUserDaoMapper userDaoMapper;

    @Autowired
    public void setUserDaoMapper(IUserDaoMapper userDaoMapper) {
        this.userDaoMapper = userDaoMapper;
    }

    @Override
    public List<User> findALL() {
        return userDaoMapper.findALL();
    }

    @Override
    public User findUserById(Integer id) {
        return userDaoMapper.findUserById(id);
    }

    @Override
    public int updateUser(User user) {
        return userDaoMapper.updateUser(user);
    }
}
